package com.vegetable.modules.entity.baseData;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.io.Serializable;
import java.math.BigDecimal;

/**
 * 发票商品明细实体
 */
@Data
@TableName("invoice_item")
public class InvoiceItem implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("主键id")
    @JsonSerialize(using = ToStringSerializer.class)
    @TableId(value = "id", type = IdType.ASSIGN_ID)
    private Long id;

    @ApiModelProperty("发票ID")
    private Long invoiceId;

    @ApiModelProperty("行号")
    private Integer rowNum;

    @ApiModelProperty("商品名称")
    private String commodityName;

    @ApiModelProperty("商品类型")
    private String commodityType;

    @ApiModelProperty("商品单位")
    private String commodityUnit;

    @ApiModelProperty("商品数量")
    private String commodityNum;

    @ApiModelProperty("商品单价")
    private BigDecimal commodityPrice;

    @ApiModelProperty("商品金额")
    private BigDecimal commodityAmount;

    @ApiModelProperty("商品税率")
    private String commodityTaxRate;

    @ApiModelProperty("商品税额")
    private BigDecimal commodityTax;

    @ApiModelProperty("商品车辆类型")
    private String commodityVehicleType;

    @ApiModelProperty("商品车牌号码")
    private String commodityPlateNum;

    @ApiModelProperty("商品有效期起始日期")
    private String commodityStartDate;

    @ApiModelProperty("商品有效期截止日期")
    private String commodityEndDate;
}